<template>
  <el-container>
    <el-header>
      <div>后台管理系统</div>
      <div @click="logout" style="cursor: pointer">
        <svg class="icon" aria-hidden="true">
          <use xlink:href="#icon-002-gift"></use>
        </svg>
        <span>退出</span>
      </div>
    </el-header>
    <el-container>
      <el-aside width="200px">
        <el-scrollbar>
          <nav-bar>
            我是pinia{{ testStore }}
          </nav-bar>
        </el-scrollbar>
      </el-aside>
      <el-main class="main">
        <router-view></router-view>
      </el-main>
    </el-container>
  </el-container>
</template>
<script setup>
import NavBar from "/@/layout/components/Navbar.vue";
import {testStore} from "/@/components/pinia/index.js";
// import { defineComponent } from "vue";
let testStoreaa = testStore();
console.log(testStoreaa.aa,'testStore')
</script>
<!-- <script lang="ts">


export default defineComponent({
  name: "Home",
  setup() {
    const logout1 = () => {
      this.$router.push({
        path: "/",
      });
    }
  },
});
</script> -->
<style lang="scss" scoped>
.el-header {
  display: flex;
  // justify-content: space-around;
  justify-content: space-between;
  background: url("/@/assets/images/title.jpg") 100%;
  color: #333;
  text-align: center;
  line-height: 60px;
}

.el-aside {
  color: #333;
  text-align: center;
  line-height: 200px;
  height: 100%;
  background-color: #e9eef3;
}

.el-main {
  color: #333;
}

.el-container {
  height: 100%;

  .el-container {
    height: calc(100% - 60px);
  }
}

.main {
  height: calc(100vh - 100px);
  overflow: auto;
  padding: 10px;
}
</style>
